The Design Notes API > The Design Notes JavaScript API > MMNotes.set() |
![]() ![]() ![]() |
Description
Creates or updates one key/value pair in a Design Notes file.
Arguments
fileHandle
, keyName
, valueString
![]() |
The first argument is the file handle returned by MMNotes.open() . |
![]() |
The second argument is a string containing the name of the key. |
![]() |
The third argument is a string containing the value. |
Returns
A Boolean value indicating whether the operation was successful.
Example
The following code opens the Design Notes file associated with a file in the dreamcentral site called peakhike99/index.html, adds a new key/value pair, changes the value of an existing key, and then closes the Note file.
var noteHandle = MMNotes.open('file:///c|sites/dreamcentral/¬ peakhike99/index.html',true); MMNotes.set(noteHandle,"Author","M. G. Miller"); MMNotes.set(noteHandle,"Last Changed","August 28, 1999"); MMNotes.close(noteHandle);
![]() ![]() ![]() |